home *** CD-ROM | disk | FTP | other *** search
/ Software of the Month Club 1996 May / Software of the Month Club 1996 May.iso / mac / ISO9660 / ZIPFILES / BMPWIZ.ZIP / MOSAIC1.BAS < prev    next >
Unknown  |  1994-02-05  |  1.3 KB

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text

This file was not able to be converted.
This format is not currently supported by dexvert.

ConfidenceProgramDetectionMatch TypeSupport
66% dexvert GW-BASIC (document/gwBasic) ext Supported
66% dexvert GFA-BASIC Atari (other/gfaBASICAtari) ext Supported
1% dexvert Amiga BASIC Protected File (other/amigaBASICProtectedFile) ext Unsupported
1% dexvert BAS VBDOS Pro 1.0 Source (other/basVBDOSPro10Source) ext Unsupported
1% dexvert Visual Basic Tokenized Source (other/visualBasicTokenizedSource) ext Unsupported
1% dexvert ZBASIC (other/zbasic) ext Unsupported
100% file data default



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 2c 05 00 00 0d 0a 27 20 | 4d 6f 73 61 69 63 2e 0d |,.....' |Mosaic..|
|00000010| 0a 27 20 43 61 6c 63 20 | 61 76 65 72 61 67 65 20 |.' Calc |average |
|00000020| 63 6f 6c 6f 72 20 6f 66 | 20 65 76 65 72 79 20 72 |color of| every r|
|00000030| 65 63 74 20 70 61 69 6e | 74 69 6e 67 20 69 6e 20 |ect pain|ting in |
|00000040| 74 68 65 20 64 65 73 74 | 69 6e 61 74 69 6f 6e 20 |the dest|ination |
|00000050| 74 68 65 20 52 47 42 20 | 76 61 6c 75 65 2e 0d 0a |the RGB |value...|
|00000060| 27 20 46 6f 72 20 61 20 | 62 65 74 74 65 72 20 61 |' For a |better a|
|00000070| 6e 64 20 66 61 73 74 65 | 72 20 72 65 73 75 6c 74 |nd faste|r result|
|00000080| 20 75 73 65 20 32 34 20 | 62 69 74 20 6f 75 74 70 | use 24 |bit outp|
|00000090| 75 74 2e 0d 0a 0d 0a 27 | 20 49 6e 70 75 74 3a 09 |ut.....'| Input:.|
|000000a0| 34 2d 38 2d 32 34 20 62 | 69 74 0d 0a 27 20 4f 75 |4-8-24 b|it..' Ou|
|000000b0| 74 70 75 74 3a 09 34 2d | 38 2d 32 34 20 62 69 74 |tput:.4-|8-24 bit|
|000000c0| 0d 0a 0d 0a 27 20 41 75 | 74 68 6f 72 3a 09 41 6e |....' Au|thor:.An|
|000000d0| 64 72 65 61 20 42 65 6e | 6f 6e 69 09 09 09 20 72 |drea Ben|oni... r|
|000000e0| 65 76 3a 09 31 2e 32 0d | 0a 0d 0a 0d 0a 73 74 72 |ev:.1.2.|.....str|
|000000f0| 69 6e 67 20 20 20 20 09 | 69 6e 70 46 69 6c 65 2c |ing .|inpFile,|
|00000100| 6f 75 74 46 69 6c 65 0d | 0a 44 65 76 43 6f 6e 09 |outFile.|.DevCon.|
|00000110| 49 62 6d 70 2c 4f 62 6d | 70 0d 0a 52 47 42 09 70 |Ibmp,Obm|p..RGB.p|
|00000120| 69 78 0d 0a 66 6c 6f 61 | 74 20 20 09 78 2c 79 2c |ix..floa|t .x,y,|
|00000130| 78 74 2c 79 74 2c 73 2c | 74 2c 72 2c 67 2c 62 0d |xt,yt,s,|t,r,g,b.|
|00000140| 0a 0d 0a 73 3d 36 0d 0a | 74 3d 31 0d 0a 69 6e 70 |...s=6..|t=1..inp|
|00000150| 46 69 6c 65 3d 22 54 65 | 73 74 69 2e 62 6d 70 22 |File="Te|sti.bmp"|
|00000160| 0d 0a 6f 75 74 46 69 6c | 65 3d 22 54 65 73 74 6f |..outFil|e="Testo|
|00000170| 2e 62 6d 70 22 0d 0a 0d | 0a 49 62 6d 70 3d 4c 6f |.bmp"...|.Ibmp=Lo|
|00000180| 61 64 49 6d 61 67 65 28 | 69 6e 70 46 69 6c 65 29 |adImage(|inpFile)|
|00000190| 0d 0a 4f 62 6d 70 3d 43 | 72 65 61 74 65 49 6d 61 |..Obmp=C|reateIma|
|000001a0| 67 65 28 49 62 6d 70 2e | 57 69 64 74 68 2c 49 62 |ge(Ibmp.|Width,Ib|
|000001b0| 6d 70 2e 48 65 69 67 68 | 74 2c 49 62 6d 70 2e 42 |mp.Heigh|t,Ibmp.B|
|000001c0| 69 74 43 6f 75 6e 74 29 | 0d 0a 0d 0a 69 66 28 28 |itCount)|....if((|
|000001d0| 49 62 6d 70 2e 42 69 74 | 43 6f 75 6e 74 3d 38 29 |Ibmp.Bit|Count=8)|
|000001e0| 09 7c 28 49 62 6d 70 2e | 42 69 74 43 6f 75 6e 74 |.|(Ibmp.|BitCount|
|000001f0| 3d 34 29 29 0d 0a 20 20 | 46 6f 72 20 79 3d 30 20 |=4)).. |For y=0 |
|00000200| 74 6f 20 32 35 35 0d 0a | 20 20 20 20 20 70 69 78 |to 255..| pix|
|00000210| 3d 47 65 74 50 61 6c 65 | 74 74 65 28 49 62 6d 70 |=GetPale|tte(Ibmp|
|00000220| 2c 79 29 0d 0a 20 20 20 | 20 20 53 65 74 50 61 6c |,y).. | SetPal|
|00000230| 65 74 74 65 28 4f 62 6d | 70 2c 79 2c 70 69 78 29 |ette(Obm|p,y,pix)|
|00000240| 0d 0a 20 20 4e 65 78 74 | 20 79 0d 0a 45 6e 64 69 |.. Next| y..Endi|
|00000250| 66 0d 0a 0d 0a 74 3d 74 | 2b 31 0d 0a 46 6f 72 20 |f....t=t|+1..For |
|00000260| 79 3d 30 20 74 6f 20 49 | 62 6d 70 2e 48 65 69 67 |y=0 to I|bmp.Heig|
|00000270| 68 74 2d 36 0d 0a 20 20 | 20 44 73 70 57 68 69 6c |ht-6.. | DspWhil|
|00000280| 65 28 22 43 6f 6e 76 65 | 72 73 69 6f 6e 65 22 2c |e("Conve|rsione",|
|00000290| 31 30 30 2f 49 62 6d 70 | 2e 48 65 69 67 68 74 2a |100/Ibmp|.Height*|
|000002a0| 79 29 0d 0a 20 20 20 73 | 3d 36 2f 49 62 6d 70 2e |y).. s|=6/Ibmp.|
|000002b0| 48 65 69 67 68 74 2a 79 | 2b 33 0d 0a 20 20 20 73 |Height*y|+3.. s|
|000002c0| 3d 73 25 28 73 2b 31 29 | 0d 0a 20 20 20 46 6f 72 |=s%(s+1)|.. For|
|000002d0| 20 78 3d 30 20 74 6f 20 | 49 62 6d 70 2e 57 69 64 | x=0 to |Ibmp.Wid|
|000002e0| 74 68 0d 0a 20 20 20 20 | 20 20 72 3d 30 0d 0a 20 |th.. | r=0.. |
|000002f0| 20 20 20 20 20 67 3d 30 | 0d 0a 20 20 20 20 20 20 | g=0|.. |
|00000300| 62 3d 30 0d 0a 20 20 20 | 20 20 20 66 6f 72 20 79 |b=0.. | for y|
|00000310| 74 3d 79 20 74 6f 20 79 | 2b 73 2d 31 0d 0a 20 20 |t=y to y|+s-1.. |
|00000320| 20 20 20 20 20 20 20 66 | 6f 72 20 78 74 3d 78 20 | f|or xt=x |
|00000330| 74 6f 20 78 2b 73 2d 31 | 09 0d 0a 20 20 20 20 20 |to x+s-1|... |
|00000340| 20 20 20 20 20 20 20 70 | 69 78 3d 47 65 74 50 69 | p|ix=GetPi|
|00000350| 78 65 6c 28 49 62 6d 70 | 2c 78 74 2c 79 74 29 0d |xel(Ibmp|,xt,yt).|
|00000360| 0a 20 20 20 20 20 20 20 | 20 20 20 20 20 72 3d 72 |. | r=r|
|00000370| 2b 70 69 78 2e 52 65 64 | 0d 0a 20 20 20 20 20 20 |+pix.Red|.. |
|00000380| 20 20 20 20 20 20 67 3d | 67 2b 70 69 78 2e 47 72 | g=|g+pix.Gr|
|00000390| 65 65 6e 0d 0a 20 20 20 | 20 20 20 20 20 20 20 20 |een.. | |
|000003a0| 20 62 3d 62 2b 70 69 78 | 2e 42 6c 75 65 0d 0a 20 | b=b+pix|.Blue.. |
|000003b0| 20 20 20 20 20 20 20 20 | 6e 65 78 74 20 78 74 0d | |next xt.|
|000003c0| 0a 20 20 20 20 20 20 6e | 65 78 74 20 79 74 0d 0a |. n|ext yt..|
|000003d0| 20 20 20 20 20 20 70 69 | 78 2e 52 65 64 3d 72 2f | pi|x.Red=r/|
|000003e0| 73 2f 73 0d 0a 20 20 20 | 20 20 20 70 69 78 2e 47 |s/s.. | pix.G|
|000003f0| 72 65 65 6e 3d 67 2f 73 | 2f 73 0d 0a 20 20 20 20 |reen=g/s|/s.. |
|00000400| 20 20 70 69 78 2e 42 6c | 75 65 3d 62 2f 73 2f 73 | pix.Bl|ue=b/s/s|
|00000410| 0d 0a 0d 0a 20 20 20 20 | 20 20 66 6f 72 20 79 74 |.... | for yt|
|00000420| 3d 79 20 74 6f 20 79 2b | 73 2d 74 0d 0a 20 20 20 |=y to y+|s-t.. |
|00000430| 20 20 20 20 20 20 66 6f | 72 20 78 74 3d 78 20 74 | fo|r xt=x t|
|00000440| 6f 20 78 2b 73 2d 74 09 | 0d 0a 20 20 20 20 20 20 |o x+s-t.|.. |
|00000450| 20 20 20 20 20 20 53 65 | 74 50 69 78 65 6c 28 4f | Se|tPixel(O|
|00000460| 62 6d 70 2c 78 74 2c 79 | 74 2c 70 69 78 29 0d 0a |bmp,xt,y|t,pix)..|
|00000470| 20 20 20 20 20 20 20 20 | 20 6e 65 78 74 20 78 74 | | next xt|
|00000480| 0d 0a 20 20 20 20 20 20 | 6e 65 78 74 20 79 74 0d |.. |next yt.|
|00000490| 0a 20 20 20 20 20 20 78 | 3d 78 2b 73 2d 31 0d 0a |. x|=x+s-1..|
|000004a0| 20 20 20 4e 65 78 74 20 | 78 0d 0a 20 20 20 79 3d | Next |x.. y=|
|000004b0| 79 2b 73 2d 31 0d 0a 4e | 65 78 74 20 79 0d 0a 50 |y+s-1..N|ext y..P|
|000004c0| 72 65 76 69 65 77 28 49 | 62 6d 70 2c 69 6e 70 46 |review(I|bmp,inpF|
|000004d0| 69 6c 65 2c 35 2c 35 29 | 0d 0a 50 72 65 76 69 65 |ile,5,5)|..Previe|
|000004e0| 77 28 4f 62 6d 70 2c 6f | 75 74 46 69 6c 65 2c 33 |w(Obmp,o|utFile,3|
|000004f0| 32 30 2c 35 29 0d 0a 0d | 0a 53 61 76 65 49 6d 61 |20,5)...|.SaveIma|
|00000500| 67 65 28 4f 62 6d 70 2c | 6f 75 74 46 69 6c 65 29 |ge(Obmp,|outFile)|
|00000510| 0d 0a 44 73 70 57 68 69 | 6c 65 28 22 22 2c 30 29 |..DspWhi|le("",0)|
|00000520| 0d 0a 44 73 70 4d 65 73 | 28 22 46 69 6e 65 22 29 |..DspMes|("Fine")|
+--------+-------------------------+-------------------------+--------+--------+